package com.sz.admin.system.pojo.po.table;

import com.mybatisflex.core.query.QueryColumn;
import com.mybatisflex.core.table.TableDef;

// Auto generate by mybatis-flex, do not modify it.
public class SysMessageTableDef extends TableDef {

    /**
     * <p>
 消息管理
 </p>

 @author sz-admin
 @since 2025-04-21
     */
    public static final SysMessageTableDef SYS_MESSAGE = new SysMessageTableDef();

    public final QueryColumn ID = new QueryColumn(this, "id");

    public final QueryColumn TITLE = new QueryColumn(this, "title");

    public final QueryColumn CONTENT = new QueryColumn(this, "content");

    public final QueryColumn DEL_FLAG = new QueryColumn(this, "del_flag");

    public final QueryColumn CREATE_ID = new QueryColumn(this, "create_id");

    public final QueryColumn SENDER_ID = new QueryColumn(this, "sender_id");

    public final QueryColumn UPDATE_ID = new QueryColumn(this, "update_id");

    public final QueryColumn CREATE_TIME = new QueryColumn(this, "create_time");

    public final QueryColumn MENU_ROUTER = new QueryColumn(this, "menu_router");

    public final QueryColumn UPDATE_TIME = new QueryColumn(this, "update_time");

    public final QueryColumn MESSAGE_TYPE_CD = new QueryColumn(this, "message_type_cd");

    /**
     * 所有字段。
     */
    public final QueryColumn ALL_COLUMNS = new QueryColumn(this, "*");

    /**
     * 默认字段，不包含逻辑删除或者 large 等字段。
     */
    public final QueryColumn[] DEFAULT_COLUMNS = new QueryColumn[]{ID, TITLE, CONTENT, CREATE_ID, SENDER_ID, UPDATE_ID, CREATE_TIME, MENU_ROUTER, UPDATE_TIME, MESSAGE_TYPE_CD};

    public SysMessageTableDef() {
        super("", "sys_message");
    }

    private SysMessageTableDef(String schema, String name, String alisa) {
        super(schema, name, alisa);
    }

    public SysMessageTableDef as(String alias) {
        String key = getNameWithSchema() + "." + alias;
        return getCache(key, k -> new SysMessageTableDef("", "sys_message", alias));
    }

}
